package com.hexacta.hrs.report;

import java.util.ArrayList;
import java.util.List;

public class Tuple {
	
	private String value1;
	
	private List<String> value2 = new ArrayList<String>();
	
	public Tuple(String value1, String value2) {
		this.value1 = value1;
		this.value2.add(value2);
	}
	
	public Tuple(String value1, List<String> value2) {
		super();
		this.value1 = value1;
		this.value2 = value2;
	}

	public String getValue1() {	
		return value1;
	}

	public void setValue1(String value1) {
		this.value1 = value1;
	}

	public List<String> getValue2() {
		return value2;
	}

	public void setValue2(List<String> value2) {
		this.value2 = value2;
	}
	
	public boolean addValue2(String value2) {
		return this.value2.add(value2);
	}

	public String getTotal() {
		Integer totalCant = 0;
		for (String cant : value2) {
			totalCant += Integer.valueOf(cant);
		}
		return totalCant.toString();
	}
	
}
